package com.intcast;

import java.util.Scanner;

/*
要写注释哦!!!
*/
public class Demo01 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int[] arr = {1, 2, 3, 4, 5, 6, 7, 8, 9};
        System.out.println("请输入开始的范围：");
        int min = sc.nextInt();
        System.out.println("请输入结束的范围：");
        int max = sc.nextInt();
        printArr(arr, min, max);
    }

    public static void printArr(int[] arr, int min, int max) {
        for (int i = min; i < max; i++) {
            System.out.print(arr[i] + "\t");
        }
    }
}
